package financial.sharing.center.system.model.entity;

import financial.sharing.center.common.base.BaseEntity;
import financial.sharing.center.common.enums.EnableStatusEnum;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.ToString;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import java.math.BigDecimal;

/**
 * @ClassName TaxRate
 * @Description TODO
 * @Author guoyuhang
 * @ @csdn https://blog.csdn.net/qq_40788718
 * @Date 2021/4/14
 * @Version 1.0
 */
@Data
@AllArgsConstructor
@ToString
@Entity
public class TaxRate extends BaseEntity {

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Integer id;
    /**税率所属地区*/
    private String taxRegion;
    /**税率类型*/
    private String taxType;
    /**税率 0.06*/
    private BigDecimal rate;

    private Integer enableStatusValue;

    public TaxRate(){

    }

    public TaxRate(String taxRegion, String taxType, BigDecimal rate) {
        this.taxRegion = taxRegion;
        this.taxType = taxType;
        this.rate = rate;
        this.enableStatusValue = EnableStatusEnum.正常.getValue();
    }
}
